package com.heqiang;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.boot.web.servlet.ServletComponentScan;
import org.springframework.cache.annotation.EnableCaching;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.scheduling.annotation.EnableScheduling;

//声明该类是一个SpringBoot引导类(相当于三个注解)
@SpringBootApplication
@EntityScan("com.heqiang.entity")//扫描实体类
@ComponentScan(basePackages={"com.heqiang.dao"})//扫描接口
@ComponentScan(basePackages={"com.heqiang"})//扫描本项目下所有类
@EnableScheduling
@EnableCaching
public class ManagerApplication {
    public static void main(String[] args) {
        //run方法 表示运行SpringBoot的引导类  run参数就是SpringBoot引导类的字节码对象
        SpringApplication.run(ManagerApplication.class);
        //加载该字节码包下的所有资源
    }
}
